<script setup>
import {ref} from "vue";
import {Search} from "@element-plus/icons-vue";

const input = ref('')

const toSearch = () => {
    window.location.href = `/user/search`;
}
</script>

<template>
    <div class="search">
        <el-input
                v-model="input"
                placeholder="请输入要查询的商家/剧本"
                class="el-input"
                clearable>
            <template #append>
                <el-button :icon="Search" @click="toSearch"/>
            </template>
        </el-input>
    </div>
</template>

<style scoped lang="scss">
.router-link {
  color: #606266;

  &:hover {
    color: #939393;
  }
}

.search {
  border-radius: 10px;
  display: flex;
  gap: 5px;

  .el-input {
    width: 300px;
    height: 40px;
  }
}
</style>